package com.yopuo.system.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.yopuo.common.utils.bean.Params;
import com.yopuo.system.domain.SysMenuCdisk;
import com.yopuo.system.mapper.SysMenuCdiskMapper;
import com.yopuo.system.service.ISysMenuCdiskService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;

/**
 * 菜单和云盘菜单关联Service业务层处理
 * 
 * @date 2020-12-13
 */
@Service
public class SysMenuCdiskServiceImpl extends ServiceImpl<SysMenuCdiskMapper,SysMenuCdisk> implements ISysMenuCdiskService
{
    @Resource
    private SysMenuCdiskMapper sysMenuCdiskMapper;

    /**
     * 查询云盘菜单
     *
     * @param userId    用户id
     * @param menuCdisk 用户权限实体类参数
     */
    @Override
    public List<SysMenuCdisk> selectPanMenu(Long userId, SysMenuCdisk menuCdisk) {
        Params params = Params.create();
        params.addEntity(menuCdisk);
        params.addParams("userId",userId);
        return sysMenuCdiskMapper.selectPanMenu(params);
    }
}
